#include <stdio.h>
#include <unistd.h>

const int BUFF_SIZE = 128;

int main() {
    char buff[BUFF_SIZE + 1];
    ssize_t buffSize;

    buffSize = readlink("./vim", buff, BUFF_SIZE);
    if (buffSize == -1) {
        perror("readlink error:");
        return 0;
    }

    buff[BUFF_SIZE] = 0;

    printf("The real path is : %s\n", buff);

    return 0;
}
